package com.atguigu.gmall.product.init;

import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringApplicationRunListener;
import org.springframework.context.ConfigurableApplicationContext;

/**
 * @author tangsy
 * @Description TODO
 * @date 2022/12/6 20:29
 * @Version 1.0
 */
@Slf4j
public class InitListener implements SpringApplicationRunListener {

    public InitListener(SpringApplication application, String[] args){
        log.info("监听器对象创建： application：{}； args:{}",application,args);
        this.application = application;
    }

    SpringApplication application;


    @Override
    public void started(ConfigurableApplicationContext context) {
        log.info("监听到项目started；skuInfoService:{}");
    }

    @Override
    public void starting() {
        log.info("监听到项目starting");
    }


}
